<template>
    <el-container>
        <el-main>
            <div id="main" style="width: 1800px;height: 600px;"></div>
        </el-main>
    </el-container>
</template>

<script>
    import echarts from 'echarts'
    export default {
        name: 'PaperCommit',
        methods:{
            drawPie(id){
                this.charts = echarts.init(document.getElementById(id))
                this.charts.setOption({
                    title: {
                        text: '频道文章统计数分析（全）'
                    },
                    xAxis: {
                        type: 'category',
                        data: ['架构', 'android', '前端', '区块链', '算法', '面试', '后端','js','人工智能','html','产品','go','javascript','css','c++','开发者资讯','linux','科技动态'
                        ,'设计','java','php','数码产品','ios','python','数据库']
                    },
                    yAxis: {
                        type: 'value'
                    },
                    series: [{
                        data: [4506, 5955, 14463, 2780, 3227, 1816, 19982,1561,9000,3015,874,3095,11976,3112,3163,533,5288,5000,1281,13198,4059,190,3241,10031,7377],
                        type: 'line'
                    }]
                })
            }
        },
        //调用
        mounted(){
            this.$nextTick(function() {
                this.drawPie('main')
            })
        }
    }
</script>

<style scoped>

</style>